package com.booza.util;

public class DecimalNumberUtils
{
	public final static int DECIMAL_PLACES = 2;	
	
	public static double roundToDecimals(double d, int c)
	{
		int temp = (int) ((d * Math.pow(10, c)));
		return (((double) temp) / Math.pow(10, c));
	}

	public static float roundToDecimals(float f, int c)
	{
		float temp = (float) Math.pow(10, c);
		f = f * temp;		
		return (float) Math.round(f) / temp;
	}
}
